<?php
//应用名称
define('APP_NAME', 'Admin');

//Loader
include realpath(dirname(dirname(dirname(__FILE__))).'/Library/Loader.php');

//后台访问密钥
if(C('admin_secret')!='' AND empty($_SESSION['admin_secret'])){
	if(isset($_GET[C('admin_secret')]))
		$_SESSION['admin_secret'] = 'true';
	else
		Header("Location: ".__ROOT__.'../');
}

//Application
MagicFactory::getInstance('Application')->run();

//debug调试控件
MagicFactory::getInstance('PageTrace')->run();